#Makefile for gpioCtl.c
-include Rules.make
ARCH?=
CROSS_COMPILE?=

ifneq ($(KERNELRELEASE),)
	obj-m := workqueue.o
else 
	KERNELDIR ?= /lib/modules/$(shell uname -r)/build
	PWD := $(shell pwd)
default:
	echo $(OBJS)
	make -C $(KERNELDIR) M=$(PWD) ARCH=$(ARCH) CROSS_COMPILE=$(CROSS_COMPILE) modules

app: app.c
	$(CROSS_COMPILE)gcc -o app app.c
clean:
	$(MAKE) -C $(KERNELDIR) M=$(PWD) clean
	rm -rf modules.order
endif
